<template>
	<div>
	<view>积分管理</view>
	<view v-for="(item,index) in UserVo" :key="item.id">
	用户名:{{item.userName}},使用途径:{{item.userWay}},剩余积分:{{item.userGrade}},积分变动:{{item.userVariation}}
	</view>
	</div>
</template>

<script>
	export default {
		data() {
			return {
				title: '积分管理',
				UserVo:{}
			}
		},
		onLoad() {
			this.handIntegralSelect()
		},
		methods: {
			handIntegralSelect(){
				const value = uni.getStorageSync('userId');
				console.log(value)
				this.userId=value
				uni.request({
				    url: `http://localhost:7000/user/IntegralSelect/${this.userId}`, //接口地址。
				    header: {
				        'custom-header': 'hello' //自定义请求头信息
				    },
					method:'POST',
				    success: (res) => {
				        console.log(res.data);
						this.UserVo=res.data.data
				    },
				})	
			}
		}
	}
</script>

<style>
</style>
